﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using System.Collections.Generic;
using System.Windows.Media.Imaging;
using System.Windows.Threading;

namespace GameSimulator.utils
{
    public class DataGenerator
    {
        static List<String> stringCollection=new List<String>();
        static List<BitmapImage> imageCollection = new List<BitmapImage>();

        public static void populateStringCollection()
        {
            stringCollection.Add("blue");
            stringCollection.Add("H2O");
            stringCollection.Add("United State");
            stringCollection.Add("gravity");
            stringCollection.Add("false");
        }

        public static String getRandomString()
        {
            Random random=new Random();
            populateStringCollection();
            return stringCollection[random.Next(0,5)];
        }

        public static void populateImageCollection()
        {
            imageCollection.Add(new BitmapImage(new Uri("../images/gallery/01.gif", UriKind.Relative)));
            imageCollection.Add(new BitmapImage(new Uri("../images/gallery/02.jpg", UriKind.Relative)));
            imageCollection.Add(new BitmapImage(new Uri("../images/gallery/03.jpg", UriKind.Relative)));
            imageCollection.Add(new BitmapImage(new Uri("../images/gallery/04.jpg", UriKind.Relative)));
        }



        public static BitmapImage getRandomImage()
        {
            Random random = new Random();
            populateImageCollection();
            return imageCollection[random.Next(-1, 4)];

        }
        public static double GetRandomNumber(double minimum, double maximum)
        {
            Random random = new Random();
            return Math.Round((random.NextDouble() * (maximum - minimum) + minimum),1) ;
        }
    }
}
